Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CELEBORN-1845][CIP-14] Add MessageDispatcher to cppClient #3077

Conversation

HolyLow
Copy link
Contributor

@HolyLow HolyLow commented Jan 21, 2025

What changes were proposed in this pull request?

This PR adds MessageDispatcher class to cppClient.

Why are the changes needed?

MessageDispatcher is responsible for recording the connection between MessageFuture and MessagePromise, which is the base of async message transferring mechanism.

Does this PR introduce any user-facing change?

No.

How was this patch tested?

Compilation and UTs.

@HolyLow HolyLow force-pushed the issue/celeborn-1845-add-message-dispatcher-to-cpp-client branch from 24e4ba2 to 57a3dca Compare January 21, 2025 10:18
@HolyLow
Copy link
Contributor Author

HolyLow commented Jan 21, 2025

@FMX @RexXiong Could you kindly help review this PR? Thanks a lot.

Any suggestion is welcome.

Copy link
Contributor

@FMX FMX left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM overall. I have checked this logic is identical to the Java implementation.

return p.getFuture();
});

this->pipeline_->write(std::move(toSendMsg));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a question here, does this writing have the semantic of flush?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The message would be transferred through the pipeline immediately, and there is no interface related to flush in Pipeline or OutboundLink (the component layers when sending out a message), so we could safely assume that this write() interface already has flushing semantic though there is no implementation guarantee.

Copy link
Contributor

@RexXiong RexXiong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@FMX FMX closed this in 39a40dd Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants